/*
 * PanelOpciones.fx
 *
 * Created on 3/10/2010, 10:06:42 PM
 */
package restaurante;

import javafx.scene.Node;
import javafx.scene.layout.Panel;
import javafx.scene.layout.LayoutInfo;
import org.netbeans.javafx.design.DesignState;
import menu.menu.Menu;
import menu.menu.MenuFX;

/**
 * @author Camilo
 * @version $Id: PanelOpciones.fx 66 2010-10-06 21:11:27Z lopezandres2002@hotmail.com $
 */
public class PanelOpciones {

    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:main
    public-read def labelMesero: javafx.scene.control.Label = javafx.scene.control.Label {
        layoutX: 6.0
        layoutY: 211.0
        text: "Llamar mesero"
    }
    
    public-read def labelChat: javafx.scene.control.Label = javafx.scene.control.Label {
        layoutX: 6.0
        layoutY: 329.0
        text: "Chat"
    }
    
    public-read def labelSugerencias: javafx.scene.control.Label = javafx.scene.control.Label {
        visible: true
        layoutX: 6.0
        layoutY: 419.0
        text: "Sugerencias"
    }
    
    public-read def colorAdjust: javafx.scene.effect.ColorAdjust = javafx.scene.effect.ColorAdjust {
        brightness: 0.00999999
        contrast: 0.78
        hue: 1.0
        saturation: 0.24000001
    }
    
    public-read def reflection: javafx.scene.effect.Reflection = javafx.scene.effect.Reflection {
        input: null
        topOffset: 0.0
        topOpacity: 0.41
        bottomOpacity: 0.0
        fraction: 0.32
    }
    
    public-read def font: javafx.scene.text.Font = javafx.scene.text.Font {
        size: 24.0
        oblique: false
        embolden: false
        autoKern: false
        ligatures: false
        position: javafx.scene.text.FontPosition.REGULAR
    }
    
    public-read def cabecera: javafx.scene.image.Image = javafx.scene.image.Image {
        url: "{__DIR__}imagenes/logo.gif"
        backgroundLoading: false
        width: 100.0
        height: 100.0
    }
    
    public-read def vistaCabecera: javafx.scene.image.ImageView = javafx.scene.image.ImageView {
        disable: false
        layoutX: 0.0
        layoutY: 0.0
        effect: reflection
        image: cabecera
        smooth: true
    }
    
    public-read def servicio: javafx.scene.image.Image = javafx.scene.image.Image {
        url: "{__DIR__}imagenes/servicio.jpg"
        backgroundLoading: false
        smooth: false
        width: 80.0
        height: 80.0
        preserveRatio: true
    }
    
    public-read def chat: javafx.scene.image.Image = javafx.scene.image.Image {
        url: "{__DIR__}imagenes/inbox.png"
        width: 80.0
        height: 80.0
        preserveRatio: true
    }
    
    public-read def sugerencia: javafx.scene.image.Image = javafx.scene.image.Image {
        url: "{__DIR__}imagenes/carta.jpg"
        smooth: true
        width: 80.0
        height: 80.0
        preserveRatio: true
    }
    
    public-read def sepiaMesero: javafx.scene.effect.SepiaTone = javafx.scene.effect.SepiaTone {
    }
    
    public-read def vistaMesero: javafx.scene.image.ImageView = javafx.scene.image.ImageView {
        layoutX: 10.0
        layoutY: 150.0
        onKeyPressed: null
        onMouseClicked: vistaMeseroOnMouseClicked
        effect: sepiaMesero
        image: servicio
    }
    
    public-read def sepiaChat: javafx.scene.effect.SepiaTone = javafx.scene.effect.SepiaTone {
    }
    
    public-read def vistaChat: javafx.scene.image.ImageView = javafx.scene.image.ImageView {
        layoutX: 10.0
        layoutY: 250.0
        onMouseClicked: vistaChatOnMouseClicked
        effect: sepiaChat
        image: chat
    }
    
    public-read def sepiaSugerencia: javafx.scene.effect.SepiaTone = javafx.scene.effect.SepiaTone {
        level: 0.7
    }
    
    public-read def vistaSugerencias: javafx.scene.image.ImageView = javafx.scene.image.ImageView {
        opacity: 1.0
        layoutX: 10.0
        layoutY: 350.0
        effect: sepiaSugerencia
        image: sugerencia
    }
    
    def __layoutInfo_panel: javafx.scene.layout.LayoutInfo = javafx.scene.layout.LayoutInfo {
        width: 100.0
        height: 768.0
    }
    public-read def panel: javafx.scene.layout.Panel = javafx.scene.layout.Panel {
        layoutInfo: __layoutInfo_panel
        content: [ vistaCabecera, vistaMesero, vistaChat, vistaSugerencias, labelMesero, labelChat, labelSugerencias, ]
    }
    
    public-read def currentState: org.netbeans.javafx.design.DesignState = org.netbeans.javafx.design.DesignState {
    }
    
    public function getDesignRootNodes (): javafx.scene.Node[] {
        [ panel, ]
    }
    // </editor-fold>//GEN-END:main

    var menu: Menu = Menu.getInstance();
    var menuFX: MenuFX = MenuFX.instance;


    function vistaChatOnMouseClicked(event: javafx.scene.input.MouseEvent): Void {
        menuFX.cambiarVisibilidad();
    }

    function vistaMeseroOnMouseClicked(event: javafx.scene.input.MouseEvent): Void {
        menu.llamarMesero();
    }

}

function run (): Void {
    var design = PanelOpciones {};

    javafx.stage.Stage {
        title: "PanelOpciones"
        scene: javafx.scene.Scene {
            content: design.getDesignRootNodes ()
        }
    }
}
